﻿namespace Fast.NormalizeActionResult
{
    /// <summary>
    /// 验证错误信息
    /// </summary>
    [SkipScan]
    public class ValidationErrorInfo
    {
        /// <summary>
        /// 模型验证错误消息
        /// </summary>
        public string Message { get; set; }

        /// <summary>
        /// 验证的对象成员
        /// </summary>
        public string[] Members { get; set; }

        /// <summary>
        /// 构造函数
        /// </summary>
        public ValidationErrorInfo()
        {

        }

        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="message"></param>
        public ValidationErrorInfo(string message)
        {
            Message = message;
        }

        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="message"></param>
        /// <param name="members"></param>
        public ValidationErrorInfo(string message, string[] members)
        {
            Message = message;
            Members = members;
        }
    }
}
